package com.foreknow.dao;

import com.foreknow.model.Guestbook;
import com.foreknow.model.student;

import java.sql.SQLException;
import java.util.List;

public interface GuestbookDao {
    /**
     * 添加留言
     * @param gb
     * @return
     */
    public boolean save(Guestbook gb)throws SQLException;

    /**
     * 查询所有信息
     * @return
     * @throws SQLException
     */
    public List<Object> getQueryAll()throws SQLException;

    /**
     * 根据Id查询留言信息
     * @param id
     * @return
     * @throws SQLException
     */
    public Guestbook getQueryById(int id)throws SQLException;

    /**
     * 根据id删除信息
     * @param id
     * @return
     * @throws SQLException
     */
    public boolean deleteById(Integer id)throws SQLException;

    /**
     * 根据id修改信息
     * @param gb
     * @return
     * @throws SQLException
     */
    boolean update(Guestbook gb)throws SQLException;
}
